/**
 * @author luther.seven@gmail.com
 */

function camPopupButtonHandler(e)
{
	var dctk = connected.toolkit;

	switch(e.buttonId)
	{
		case dcKeyEvent.BUTTON_ID_BACK:
		{
			dctk.dismissPopup();
		}
		break;

	}
}

function showCamPopup()
{
	var dctk = connected.toolkit;
	
	// create a new panel for the popup
	var camPopup = dctk.createPanelCtrl("camPopup", true);
	camPopup.width = 440;
	camPopup.height = 200;
	camPopup.outlined = true;
	camPopup.filled = true;
	camPopup.color.rgb = 0x000000;
	camPopup.color.a = 192;
	camPopup.onUnhandledKeyEvent = camPopupButtonHandler;
	
	itemList = dctk.createFilmstripCtrl("itemList", true);
    itemList.setRect(20, 20, 420, 260);
	itemList.reflect = true;
	itemList.style = dctkIFilmstrip.FILMSTRIP_STYLE_HORIZONTAL_MIDDLE;
	itemList.scrollBarWidth = 0;
	itemList.textColor.rgb = 0xFFFFFF;
	camPopup.addChild(itemList);
	
	dctk.invokePopup(camPopup);

}

